<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <script>
        var m=0;
        for(var n=20;n<=80;n++){
            if(n%3==0){
                document.write(n+" ");
                m++;
            }
            if(m%5==0){
                document.write("<br>");
            }
        }
    </script>
</body>
</html>